Skip to content

Feature/add props for close button#9

Merged
MrsLecter merged 2 commits intomasterfrom
feature/add-props-for-close-button
Jan 28, 2026
Merged

Feature/add props for close button#9
MrsLecter merged 2 commits intomasterfrom
feature/add-props-for-close-button

Conversation

@MrsLecter
Copy link
Copy Markdown

@MrsLecter MrsLecter commented Jan 28, 2026

Summary by CodeRabbit

  • New Features

    • Added customizable padding and close button positioning options to the datepicker component for enhanced styling flexibility.
    • Expanded Storybook demo controls to adjust datepicker styling parameters interactively.
  • Bug Fixes

    • Fixed Close component to conditionally render text, preventing empty text elements from affecting layout.
  • Chores

    • Version bumped to 1.0.4.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jan 28, 2026

Caution

Review failed

The pull request is closed.

Walkthrough

The styled components package is updated to version 1.0.4 with improvements to component rendering and styling customization. The Close component now conditionally renders its closeText element. DateRangeInputModern and Datepicker components replace the datepickerZIndex prop with two new props—datepickerPadding and datepickerCloseWrapperRight—enabling more granular control over padding and close button positioning.

Changes

Cohort / File(s) Summary
Version Update
packages/styled/package.json
Version bumped from 1.0.3 to 1.0.4
Close Component Rendering
packages/styled/src/components/Close/Close.tsx
Added conditional rendering for closeText Text element; text now only renders when closeText is truthy, while CloseIcon remains unconditional
DateRangeInputModern Styling Props
packages/styled/src/components/DateRangeInputModern/DateRangeInputModern.tsx, DateRangeInputModern.stories.tsx
Added optional props datepickerPaddingCustom and datepickerCloseWrapperRightCustom (both string | null); removed datepickerZIndexCustom prop; updated stories with Storybook knobs for new props
Datepicker Styling Props
packages/styled/src/components/Datepicker/Datepicker.tsx, Datepicker.stories.tsx
Added optional props datepickerPadding and datepickerCloseWrapperRight (both string | null); removed datepickerZIndex prop; StyledDatepicker padding now uses custom prop with theme fallback; close wrapper right positioning now uses custom prop with theme fallback; updated stories with Storybook knobs

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~28 minutes

Poem

🐰✨ New props dance, old zIndex fades away,
Padding and wrapper-right guide the display!
Close text whispers softly when it's there to stay,
Theming grows stronger, version 1.0.4's way! 🎨

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/add-props-for-close-button

Comment @coderabbitai help to get the list of available commands and usage tips.

@MrsLecter MrsLecter merged commit dee0bf3 into master Jan 28, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant